<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>Document</title>
</head>
<body>
    
</body>
<script>
    var name=prompt('请输入明明购买的商品名称：')
    var age=prompt('请输入明明购买的商品数量：')
    document.write("<h1>购物清单</h1>");
	document.write("商品名称&nbsp购买数量<br />");
	document.write(name+"&nbsp&nbsp&nbsp&nbsp&nbsp&nbsp&nbsp&nbsp&nbsp&nbsp"+age);
</script>
</html>